//
//  CTShare.h
//  ConstellationTalk_0.1
//
//  Created by riley on 15/5/12.
//  Copyright (c) 2015年 riley chu. All rights reserved.
//

#import <Foundation/Foundation.h>
@class CTShareItem;


typedef void (^CTShareSuccessedBlock)();
typedef void (^CTShareFailedBlock)();


typedef enum{
    //oversea
    CTShareChannelFaceBook = 0,
    CTShareChannelTwitter,
    CTShareChannelLine,
    CTShareChannelWhatsapp,
    CTShareChannelInstagram,
    //internal
    CTShareChannelWechat,
    CTShareChannelWechatFriend,
    CTShareChannelQQ,
    CTShareChannelQQSpace,
    CTShareChannelSina,
    //local
    CTShareChannelMessage,
    CTShareChannelEmail
}CTShareChannel;

typedef enum {
    CTPublishTypeText = 0,
    CTPublishTypeImage,
    CTPublishTypeNews
}CTPublishType;



@interface CTShare : NSObject

//判断无界面分享
+ (BOOL)isSinaShare;
+ (void)setSinaShare:(BOOL)share;
+ (void)sinaBtnAction:(CTShareItem *)itm
  shareSuccessHandler:(CTShareSuccessedBlock)successBlock
   shareFailedHandler:(CTShareFailedBlock)failedBlock;



+(void)shareItem:(CTShareItem *)item
    shareChannel:(CTShareChannel)shareChannel
     publishType:(CTPublishType)pubtype
shareSuccessHandler:(CTShareSuccessedBlock)successBlock
shareFailedHandler:(CTShareFailedBlock)failedBlock;

@end
